package com.luhuiguo.cms.server.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.luhuiguo.cms.server.service.ArticleService;
import com.luhuiguo.cms.server.service.AttachmentService;
import com.luhuiguo.cms.server.service.ChannelService;
import com.luhuiguo.cms.server.service.CmsService;
import com.luhuiguo.cms.server.service.UserService;
import com.luhuiguo.cms.server.service.impl.ArticleServiceImpl;
import com.luhuiguo.cms.server.service.impl.AttachmentServiceImpl;
import com.luhuiguo.cms.server.service.impl.ChannelServiceImpl;
import com.luhuiguo.cms.server.service.impl.CmsServiceImpl;
import com.luhuiguo.cms.server.service.impl.UserServiceImpl;

/**
 * The spring java-based configuration for services.
 * 
 * @author LuHuiguo
 * @version $Id: ServiceConfig.java 149 2010-05-07 01:34:19Z luhuiguo@gmail.com
 *          $
 */
@Configuration
public class ServiceConfig {

    @Bean
    public UserService userService() {
        return new UserServiceImpl();
    }

    @Bean
    public ChannelService channelService() {
        return new ChannelServiceImpl();
    }

    @Bean
    public ArticleService articleService() {
        return new ArticleServiceImpl();
    }

    @Bean
    public AttachmentService attachmentService() {
        return new AttachmentServiceImpl();
    }

    @Bean
    public CmsService cmsService() {
        return new CmsServiceImpl();
    }
}
